/**
 * There are <a href="https://github.com/thinkgem/jeesite">JeeSite</a> code generation
 */
package com.chlitina.store.modules.expert.entity;

import java.io.Serializable;

/**
 * 复合主键
 * @author liujiang
 * @version 2013-06-07
 */
public class MinMaxValuePK implements Serializable{
	
	private static final long serialVersionUID = 1L;
	private Long min_value; // 范围
	private Long max_value; // 范围
	
	public MinMaxValuePK() {
		
	}
	
	public MinMaxValuePK(Long min_value, Long max_value) {
		this.min_value = min_value;
		this.max_value = max_value;
	}
	
	public Long getMin_value() {
		return min_value;
	}

	public void setMin_value(Long min_value) {
		this.min_value = min_value;
	}

	public Long getMax_value() {
		return max_value;
	}

	public void setMax_value(Long max_value) {
		this.max_value = max_value;
	}
	
	@Override
	public int hashCode() {
		return this.min_value.hashCode() + this.max_value.hashCode();
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		final MinMaxValuePK other = (MinMaxValuePK) obj;
		if ((min_value + max_value) == (other.getMin_value() + other.getMax_value())) {
			return true;
		} 
		return false;
	}
}


